package com.zzsz.mapper;

import com.zzsz.domain.RecipientQueryDTO;
import com.zzsz.domain.WaringRecipient;
import org.apache.ibatis.annotations.Mapper;


import java.util.List;

@Mapper
public interface RecipientMapper {


	/**
	 * 查找全部预警接收人
	 *
	 * @return 预警接收人列表
	 */
	List<WaringRecipient> selectAll(RecipientQueryDTO recipientQueryDTO);

	/**
	 * 添加预警接收人
	 * @param waringRecipient 预警接收人信息
	 * @return 影响行数
	 */
	int insert(WaringRecipient waringRecipient);

	/**
	 * 更新预警接收人
	 * @param waringRecipient 预警接收人信息
	 * @return 影响行数
	 */
	int update(WaringRecipient waringRecipient);

	/**
	 * 根据ID删除预警接收人
	 * @param recipientId 接收人ID
	 * @return 影响行数
	 */
	int deleteById(Integer recipientId);

	WaringRecipient selectByCategoryId(Integer CategoryId);

	WaringRecipient selectMaster();

	/**
	 * 批量添加预警接收人
	 * @param recipientList 预警接收人列表
	 * @return 影响行数
	 */
	int batchInsert(List<WaringRecipient> recipientList);
}